additions
[TesnorFlow-Exercises.git] / Python API r1.8 Guide Summaries / Variables.md
blobc8441f7c099d0e557241a037278ef739f2388a23
1 Variables
3 Mostly basic stuff.
5 * tf.Variable // Class. Variable maintains state in graph. Requires initial value. 
6 __init__(
7     initial_value=None,
8     trainable=True,
9     collections=None,
10     validate_shape=True,
11     caching_device=None,
12     name=None,
13     variable_def=None,
14     dtype=None,
15     expected_shape=None,
16     import_scope=None,
17     constraint=None
20 Variable helper functions
21 TensorFlow provides a set of functions to help manage the set of variables collected in the graph.
22 * tf.global_variables(scope=None) // Sharec accross machine evn
23 * tf.local_variables // 
24 * tf.model_variables // 
25 * tf.trainable_variables // 
26 * tf.moving_average_variables // 
27 * tf.global_variables_initializer // 
28 * tf.local_variables_initializer // 
29 * tf.variables_initializer // 
30 * tf.is_variable_initialized // 
31 * tf.report_uninitialized_variables // 
32 * tf.assert_variables_initialized // 
33 * tf.assign(
34     ref,
35     value,
36     validate_shape=None,
37     use_locking=None,
38     name=None
39 ) // Updates a ref by assigning it a vlue
40 * tf.assign_add(
41     ref,
42     value,
43     use_locking=None,
44     name=None
45 ) // Same but adding
46 * tf.assign_sub(
47     ref,
48     value,
49     use_locking=None,
50     name=None
51 ) // same but subtracking
53 Saving and Restoring Variables
54 * tf.train.Saver // 
55 * tf.train.latest_checkpoint // 
56 * tf.train.get_checkpoint_state // 
57 * tf.train.update_checkpoint_state //